<h2>Benutzerdaten bearbeiten</h2>


<?php echo validation_errors(); ?>
<?php echo form_open('user_controller/validate') ?>
<?php #$row = $user->row();?>
	<input type="input" name="userid" hidden="true" value=<?php echo $user['id'];?> />
	<label for="Username">Username:</label>
	<input type="input" name="Username" value=<?php echo $user['username'];?> /><br />
	<label for="Password">Password:</label>
	<input type="input" name="Password" /><br />
	<label for="Admin">Admin:</label>
	<?php if ($user['Admin'] == 1)
	{ 
	?>
		<input type="checkbox" name="Admin" checked="checked"/><br />
	<?php 
	}	
	else
	{ 
	?>
		<input type="checkbox" name="Admin"/><br />
	<?php 
	} 
	?>
	<label for="Lehrer">Lehrer:</label>
	<?php if ($user['Lehrer'] == 1)
	{
	?>
		<input type="checkbox" name="Lehrer" checked="checked"/><br />
	<?php
	}	
	else
	{
	?>
		<input type="checkbox" name="Lehrer"/><br />
	<?php
	}
	?>
	<label for="Schueler">Schüler:</label>
	<?php if ($user['Schueler'] == 1)
	{
	?>
		<input type="checkbox" name="Schueler" checked="checked"/><br />
	<?php
	}	
	else
	{
	?>
		<input type="checkbox" name="Schueler"/><br />
	<?php
	}
	?>
	<!--
	<label for="Fach">Fach</label>
	<select name="Fach">
		<option value="1">Mathe</option>
		<option value="2">Deutsch</option>
		<option value="3">Englisch</option>
	</select><br />
	-->

	<input class="art-button" type="submit" name="submit" value="Ändern" />

</form>